<template>
  <div id="app">
    <div class="sakura-header">
      <Header v-if="isComponentVisible" />

    </div>
    <keep-alive>
      <router-view :key="$route.fullPath" />
    </keep-alive>
    <Footer></Footer>
  </div>
</template>

<script>
import Header from "@/components/Header";
import Chat from "@/views/chat/Chat";
import Footer from "@/components/Footer";
export default {
  name: 'app',
  components: {Footer, Chat, Header},
  computed: {
    isComponentVisible() {
      // 判断当前路由是否是需要隐藏组件的页面
      document.title = "医疗智能对话系统";
      return this.$route.name !== 'Login'
    }
  }
}
</script>

<style>
.sakura-header {
  margin: 0 auto;
  position: relative;
  width: 90%;
  height: 100%;
  /* min-width: 994px; */
}

</style>
